<?php

include("include_weblog_api.php");
include("../inc/config.inc.php");
include($cfile); 
include("smallaxe_api.php");
include("xmlrpc.class.php");
include("xmlrpcfunctions.php");
record_request($HTTP_RAW_POST_DATA);
$xmlrpc_request = XMLRPC_parse($HTTP_RAW_POST_DATA);
$methodName = XMLRPC_getMethodName($xmlrpc_request);
$params = XMLRPC_getParams($xmlrpc_request);
if(!isset($xmlrpc_methods[$methodName])){
    $xmlrpc_methods['method_not_found']($methodName);
}else{
	if($methodName = "blogger2.newPost") { 
		$xmlrpc_methods[$methodName]($HTTP_RAW_POST_DATA);
	} else { 
		#call the method
		$xmlrpc_methods[$methodName]($params);
	}
}
?>